home *** CD-ROM | disk | FTP | other *** search
/ PC World Komputer 2010 April / PCWorld0410.iso / pluginy Firefox / 60750 / 60750.xpi / chrome / chromeFiles / content / btClient.js < prev    next >
Text File  |  2010-01-20  |  2KB  |  70 lines

  1. /* This file contains all client information */
  2. /* It HAS to be included first. */
  3.  
  4. if (typeof(BrandThunder) == "undefined") {
  5.   BrandThunder = {};
  6.   BrandThunder.clients = {};
  7. }
  8.  
  9. BrandThunder.clients.collegehumor = {
  10.   "shortName": "collegehumor",
  11.   "clientName": "CollegeHumor",
  12.   "clientCode": "000209",
  13.   "askOriginCode": "101519",
  14.   "bingFormCode": "BT075D",
  15.   "clientVersion": "001",
  16.   "clientCountry": "US",
  17.   "rebrandID": "",
  18.   "extensionID": "collegehumorboom@collegehumor.com",
  19.   /* Used for uninstalling theme */
  20. //  "themeID": "collegehumortheme@collegehumor.com",
  21.   /* This is the short name used in chrome.manifest (toolbar) */
  22.   "packageName": "collegehumorboom",
  23.   "welcomePage": "http://pages.brandthunder.com/collegehumor/firstrun",
  24.   "homePage": "http://www.collegehumor.com/",
  25. //  "toolbarUpdateURL": "http://brandthunder.com/clientCategory/collegehumor/toolbar.json",
  26.   "defaultSearchEngine": "Bing - BT",
  27.   "firstRunSidebar": "bt-collegehumor-sidebar",
  28.   "booms": {
  29.     "collegehumor": "CollegeHumor"
  30.   }
  31. }
  32.  
  33.  
  34. /* I hate this, but I don't see any way around it. Firefox toggleSidebar doesn't
  35.    allow for custom parameters and we need them. */
  36. /*
  37. if (typeof(toggleSidebar) != "undefined") {
  38.   if (!toggleSidebar.btReplaced) {
  39.     var origToggleSidebar = toggleSidebar;
  40.     
  41.     function btToggleSidebar(commandID, forceOpen) {
  42.       if (commandID) {
  43.         if (commandID.substring(0,3) == "bt-") {
  44.           var sidebarBox = document.getElementById("sidebar-box");
  45.           var commands = commandID.split('?');
  46.           if (commands.length > 1) {
  47.             sidebarBox.setAttribute("btSidebarParams", commands[1]);
  48.             if (!document.getElementById("sidebar-box").hidden) {
  49.               var sidebarid = window.top.document.getElementById("sidebar-box").getAttribute("sidebarcommand");
  50.               var sidebarurl = window.top.document.getElementById('sidebar').getAttribute("src");
  51.               if (sidebarid == commands[0]) {
  52.                 if (!(sidebarurl.match(commands[1]))) {
  53.                     origToggleSidebar();
  54.                 }
  55.               }
  56.             }
  57.           }
  58.           commandID = commands[0];
  59.         }
  60.       }
  61.       origToggleSidebar(commandID, forceOpen);
  62.     }
  63.     
  64.     toggleSidebar = btToggleSidebar;
  65.     toggleSidebar.btReplaced = true;    
  66.     toggleSidebar.origToggleSidebar = origToggleSidebar;
  67.   }
  68. }
  69. */
  70.